<?php

class SJB_Admin_Classifieds_GetTree extends SJB_Function
{
	public function isAccessible()
	{
		return true;
	}

	public function execute()
	{
		$treeHelper = new SJB_TreeHelper('listing');
		$treeHelper->init();
		if ($treeHelper->get_displayAsSelectBoxes())
			$treeHelper->getDisplayAsSelectBoxes();
		else
			$treeHelper->getDisplayAsTree();
		exit;
	}
}